import 'package:finance_app/src/entities/setting_template_entity.dart';

settingTemplateEntityFromJson(SettingTemplateEntity data, Map<String, dynamic> json) {
	if (json['type'] != null) {
		data.type = json['type'].toString();
	}
	if (json['template'] != null) {
		data.template = json['template'].toString();
	}
	if (json['image_url'] != null) {
		data.imageUrl = json['image_url'].toString();
	}
	return data;
}

Map<String, dynamic> settingTemplateEntityToJson(SettingTemplateEntity entity) {
	final Map<String, dynamic> data = new Map<String, dynamic>();
	data['type'] = entity.type;
	data['template'] = entity.template;
	data['image_url'] = entity.imageUrl;
	return data;
}